<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
	<head>
		<meta http-equiv="content-type" content="text/html; charset=utf-8" />
		<meta name="generator" content="JsDoc Toolkit" />
		
		<title>JsDoc Reference - APIVK</title>

		<style type="text/css">
			/* default.css */
body
{
	font: 12px "Lucida Grande", Tahoma, Arial, Helvetica, sans-serif;
	width: 800px;
}

.header
{
	clear: both;
	background-color: #ccc;
	padding: 8px;
}

h1
{
	font-size: 150%;
	font-weight: bold;
	padding: 0;
	margin: 1em 0 0 .3em;
}

hr
{
	border: none 0;
	border-top: 1px solid #7F8FB1;
	height: 1px;
}

pre.code
{
	display: block;
	padding: 8px;
	border: 1px dashed #ccc;
}

#index
{
	margin-top: 24px;
	float: left;
	width: 160px;
	position: absolute;
	left: 8px;
	background-color: #F3F3F3;
	padding: 8px;
}

#content
{
	margin-left: 190px;
	width: 600px;
}

.classList
{
	list-style-type: none;
	padding: 0;
	margin: 0 0 0 8px;
	font-family: arial, sans-serif;
	font-size: 1em;
	overflow: auto;
}

.classList li
{
	padding: 0;
	margin: 0 0 8px 0;
}

.summaryTable { width: 100%; }

h1.classTitle
{
	font-size:170%;
	line-height:130%;
}

h2 { font-size: 110%; }
caption, div.sectionTitle
{
	background-color: #7F8FB1;
	color: #fff;
	font-size:130%;
	text-align: left;
	padding: 2px 6px 2px 6px;
	border: 1px #7F8FB1 solid;
}

div.sectionTitle { margin-bottom: 8px; }
.summaryTable thead { display: none; }

.summaryTable td
{
	vertical-align: top;
	padding: 4px;
	border-bottom: 1px #7F8FB1 solid;
	border-right: 1px #7F8FB1 solid;
}

/*col#summaryAttributes {}*/
.summaryTable td.attributes
{
	border-left: 1px #7F8FB1 solid;
	width: 140px;
	text-align: right;
}

td.attributes, .fixedFont
{
	line-height: 15px;
	color: #002EBE;
	font-family: "Courier New",Courier,monospace;
	font-size: 13px;
}

.summaryTable td.nameDescription
{
	text-align: left;
	font-size: 13px;
	line-height: 15px;
}

.summaryTable td.nameDescription, .description
{
	line-height: 15px;
	padding: 4px;
	padding-left: 4px;
}

.summaryTable { margin-bottom: 8px; }

ul.inheritsList
{
	list-style: square;
	margin-left: 20px;
	padding-left: 0;
}

.detailList {
	margin-left: 20px; 
	line-height: 15px;
}
.detailList dt { margin-left: 20px; }

.detailList .heading
{
	font-weight: bold;
	padding-bottom: 6px;
	margin-left: 0;
}

.light, td.attributes, .light a:link, .light a:visited
{
	color: #777;
	font-style: italic;
}

.fineprint
{
	text-align: right;
	font-size: 10px;
}
		</style>
	</head>

	<body>
<!-- ============================== header ================================= -->	
		<!-- begin static/header.html -->
		<div id="header">
</div>
		<!-- end static/header.html -->

<!-- ============================== classes index ============================ -->
		<div id="index">
			<!-- begin publish.classesIndex -->
			<div align="center"><a href="../index.html">Class Index</a>
| <a href="../files.html">File Index</a></div>
<hr />
<h2>Classes</h2>
<ul class="classList">
	
	<li><i><a href="../symbols/_global_.html">_global_</a></i></li>
	
	<li><a href="../symbols/APIVK.html">APIVK</a></li>
	
</ul>
<hr />
			<!-- end publish.classesIndex -->
		</div>
		
		<div id="content">
<!-- ============================== class title ============================ -->
			<h1 class="classTitle">
				
				Class APIVK
			</h1>

<!-- ============================== class summary ========================== -->			
			<p class="description">
				
				
			
				
				
				
					<br /><i>Defined in: </i> <a href="../symbols/src/src_apivk.js.html">apivk.js</a>.
				
			</p>

<!-- ============================== constructor summary ==================== -->			
			
			<table class="summaryTable" cellspacing="0" summary="A summary of the constructor documented in the class APIVK.">
				<caption>Class Summary</caption>
				<thead>
					<tr>
						<th scope="col">Constructor Attributes</th>
						<th scope="col">Constructor Name and Description</th>
					</tr>
				</thead>
				<tbody>
					<tr>
						<td class="attributes">&nbsp;</td>
						<td class="nameDescription" >
							<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#constructor">APIVK</a></b>(api_secret, success, error, test_mode)
							</div>
							<div class="description">Create new object to call Vkontakte API throurh it.</div>
						</td>
					</tr>
				</tbody>
			</table>
			

<!-- ============================== properties summary ===================== -->
			
				
				
				<table class="summaryTable" cellspacing="0" summary="A summary of the fields documented in the class APIVK.">
					<caption>Field Summary</caption>
					<thead>
						<tr>
							<th scope="col">Field Attributes</th>
							<th scope="col">Field Name and Description</th>
						</tr>
					</thead>
					<tbody>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#external">external</a></b>
								</div>
								<div class="description">map VK.External methods to APIVK.external</div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#params">params</a></b>
								</div>
								<div class="description">Parameters, which were sent to application through request string</div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#SETT_AUDIO">SETT_AUDIO</a></b>
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#SETT_FRIENDS">SETT_FRIENDS</a></b>
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#SETT_MENU">SETT_MENU</a></b>
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#SETT_NOTIFY">SETT_NOTIFY</a></b>
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#SETT_OFFER">SETT_OFFER</a></b>
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#SETT_PHOTOS">SETT_PHOTOS</a></b>
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#SETT_QUESTIONS">SETT_QUESTIONS</a></b>
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#SETT_WALL">SETT_WALL</a></b>
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont">
								<b><a href="../symbols/APIVK.html#SETT_WIKI">SETT_WIKI</a></b>
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
					</tbody>
				</table>
				
				
				
			

<!-- ============================== methods summary ======================== -->
			
				
				
				<table class="summaryTable" cellspacing="0" summary="A summary of the methods documented in the class APIVK.">
					<caption>Method Summary</caption>
					<thead>
						<tr>
							<th scope="col">Method Attributes</th>
							<th scope="col">Method Name and Description</th>
						</tr>
					</thead>
					<tbody>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont"><b><a href="../symbols/APIVK.html#addCallback">addCallback</a></b>(String, Function)
								</div>
								<div class="description">Add callback function.</div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont"><b><a href="../symbols/APIVK.html#call">call</a></b>(method, req)
								</div>
								<div class="description">Call Vkontakte API method.</div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont"><b><a href="../symbols/APIVK.html#callMethod">callMethod</a></b>(String)
								</div>
								<div class="description">Call external method.</div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont"><b><a href="../symbols/APIVK.html#getProfile">getProfile</a></b>(uid, onReady)
								</div>
								<div class="description"></div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont"><b><a href="../symbols/APIVK.html#getProfileInit">getProfileInit</a></b>(maxCachedRecords, collectingInterval, fields)
								</div>
								<div class="description">initialize apivk.profiles.js plugin</div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont"><b><a href="../symbols/APIVK.html#makeInstall">makeInstall</a></b>(ifInstalled)
								</div>
								<div class="description">Ask user to install application (add to their page) in indefinite
loop until user finally installs application.</div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont"><b><a href="../symbols/APIVK.html#makeSettings">makeSettings</a></b>(settings)
								</div>
								<div class="description">Ask user to set appropriate settings and wait for user to do it.</div>
							</td>
						</tr>
					
						<tr>
							<td class="attributes">&nbsp;</td>
							<td class="nameDescription">
								<div class="fixedFont"><b><a href="../symbols/APIVK.html#removeCallback">removeCallback</a></b>(String, Number)
								</div>
								<div class="description">Remove callback function from the queue.</div>
							</td>
						</tr>
					
					</tbody>
				</table>
				
				
				
			
<!-- ============================== events summary ======================== -->
			

<!-- ============================== constructor details ==================== -->		
			
			<div class="details"><a name="constructor"> </a>
				<div class="sectionTitle">
					Class Detail
				</div>
				
				<div class="fixedFont">
						<b>APIVK</b>(api_secret, success, error, test_mode)
				</div>
				
				<div class="description">
					Create new object to call Vkontakte API throurh it.
					
				</div>
				
				
				
				
					
						<dl class="detailList">
						<dt class="heading">Parameters:</dt>
						
							<dt>
								<span class="light fixedFont">{String}</span>  <b>api_secret</b>
								
							</dt>
								<dd>Application sercet (can be
changed on application edit page).</dd>
						
							<dt>
								<span class="light fixedFont">{Function}</span>  <b>success</b>
								
							</dt>
								<dd>Function to perform after API
initialised.</dd>
						
							<dt>
								<span class="light fixedFont">{Function}</span>  <b>error</b>
								
							</dt>
								<dd>Function to perform if API
initialisation fails for msome reason.</dd>
						
							<dt>
								<span class="light fixedFont">{Boolean}</span>  <b>test_mode</b>
								
							</dt>
								<dd>If set to true then all
requests will be executed in test mode - additional parameter
test_mode=1 will be automatically added to every API request, so
you needn't do it manually.</dd>
						
						</dl>
					
					
					
					
					
					
					

			</div>
			

<!-- ============================== field details ========================== -->		
			
				<div class="sectionTitle">
					Field Detail
				</div>
				
					<a name="external"> </a>
					<div class="fixedFont">
					
					<span class="light">{Object}</span>
					<b>external</b>
					
					</div>
					<div class="description">
						map VK.External methods to APIVK.external
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="params"> </a>
					<div class="fixedFont">
					
					<span class="light">{Object}</span>
					<b>params</b>
					
					</div>
					<div class="description">
						Parameters, which were sent to application through request string
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="SETT_AUDIO"> </a>
					<div class="fixedFont">
					
					<span class="light">{Number}</span>
					<b>SETT_AUDIO</b>
					
					</div>
					<div class="description">
						
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="SETT_FRIENDS"> </a>
					<div class="fixedFont">
					
					<span class="light">{Number}</span>
					<b>SETT_FRIENDS</b>
					
					</div>
					<div class="description">
						
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="SETT_MENU"> </a>
					<div class="fixedFont">
					
					<span class="light">{Number}</span>
					<b>SETT_MENU</b>
					
					</div>
					<div class="description">
						
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="SETT_NOTIFY"> </a>
					<div class="fixedFont">
					
					<span class="light">{Number}</span>
					<b>SETT_NOTIFY</b>
					
					</div>
					<div class="description">
						
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="SETT_OFFER"> </a>
					<div class="fixedFont">
					
					<span class="light">{Number}</span>
					<b>SETT_OFFER</b>
					
					</div>
					<div class="description">
						
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="SETT_PHOTOS"> </a>
					<div class="fixedFont">
					
					<span class="light">{Number}</span>
					<b>SETT_PHOTOS</b>
					
					</div>
					<div class="description">
						
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="SETT_QUESTIONS"> </a>
					<div class="fixedFont">
					
					<span class="light">{Number}</span>
					<b>SETT_QUESTIONS</b>
					
					</div>
					<div class="description">
						
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="SETT_WALL"> </a>
					<div class="fixedFont">
					
					<span class="light">{Number}</span>
					<b>SETT_WALL</b>
					
					</div>
					<div class="description">
						
						
						
					</div>
					
					

						
						
						
						

					<hr />
				
					<a name="SETT_WIKI"> </a>
					<div class="fixedFont">
					
					<span class="light">{Number}</span>
					<b>SETT_WIKI</b>
					
					</div>
					<div class="description">
						
						
						
					</div>
					
					

						
						
						
						

					
				
			

<!-- ============================== method details ========================= -->		
			
				<div class="sectionTitle">
					Method Detail
				</div>
				
					<a name="addCallback"> </a>
					<div class="fixedFont">
					
					
					<b>addCallback</b>(String, Function)
					
					</div>
					<div class="description">
						Add callback function.
						
						
					</div>
					
					
					
						
							<dl class="detailList">
							<dt class="heading">Parameters:</dt>
							
								<dt>
									<b>String</b>
									
								</dt>
								<dd>name Name of event to which callback
                   will be added.</dd>
							
								<dt>
									<b>Function</b>
									
								</dt>
								<dd>callback Callback function to run
                         after event 'name' occurs.</dd>
							
							</dl>
						
						
						
						
						
							<dl class="detailList">
							<dt class="heading">Returns:</dt>
							
								<dd>Number ID of assigned callback function.</dd>
							
							</dl>
						
						
						

					<hr />
				
					<a name="call"> </a>
					<div class="fixedFont">
					
					
					<b>call</b>(method, req)
					
					</div>
					<div class="description">
						Call Vkontakte API method.
						
						
					</div>
					
					
					
						
							<dl class="detailList">
							<dt class="heading">Parameters:</dt>
							
								<dt>
									<span class="light fixedFont">{String}</span> <b>method</b>
									
								</dt>
								<dd>Method name to execute.</dd>
							
								<dt>
									<span class="light fixedFont">{Object}</span> <b>req</b>
									<i>Optional</i>
								</dt>
								<dd>see below</dd>
							
								<dt>
									<span class="light fixedFont">{Object}</span> <b>req.params</b>
									
								</dt>
								<dd>Parameters of API method in the following
                         form:
                         {
                             name1: 'value 1',
                             name2: 'value 2',

                             //arrays are also allowed
                             name3: [
                                 'array_value_1',
                                 'array_value_2',
                                 'array_value_3'
                             ]
                         }</dd>
							
								<dt>
									<span class="light fixedFont">{Function}</span> <b>req.success</b>
									
								</dt>
								<dd>Callback function to perform when
answer from API call comes from server.  success(data), data -
content of "response" json node</dd>
							
								<dt>
									<span class="light fixedFont">{Function}</span> <b>req.error</b>
									
								</dt>
								<dd>Callback function to perform when
answer from API call comes from server.  error(code, msg,
reqParams)</dd>
							
							</dl>
						
						
						
						
						
						
						

					<hr />
				
					<a name="callMethod"> </a>
					<div class="fixedFont">
					
					
					<b>callMethod</b>(String)
					
					</div>
					<div class="description">
						Call external method.
						
						
					</div>
					
					
					
						
							<dl class="detailList">
							<dt class="heading">Parameters:</dt>
							
								<dt>
									<b>String</b>
									
								</dt>
								<dd>method Method name to call. You can
                     call methods from external.*
                     (VK.External.*) with proper
                     parameters.</dd>
							
							</dl>
						
						
						
						
						
						
						

					<hr />
				
					<a name="getProfile"> </a>
					<div class="fixedFont">
					
					
					<b>getProfile</b>(uid, onReady)
					
					</div>
					<div class="description">
						
						
							<br />
							<i>Defined in: </i> <a href="../symbols/src/plugins_apivk.profiles.js.html">apivk.profiles.js</a>.
						
						
					</div>
					
					
					
						
							<dl class="detailList">
							<dt class="heading">Parameters:</dt>
							
								<dt>
									<b>uid</b>
									
								</dt>
								<dd>user id</dd>
							
								<dt>
									<span class="light fixedFont">{Function}</span> <b>onReady</b>
									
								</dt>
								<dd>onReady(data). Object "data" contain
fields, which were specifing in <a href="#getProfileInit">#getProfileInit</a></dd>
							
							</dl>
						
						
						
						
						
						
						

					<hr />
				
					<a name="getProfileInit"> </a>
					<div class="fixedFont">
					
					
					<b>getProfileInit</b>(maxCachedRecords, collectingInterval, fields)
					
					</div>
					<div class="description">
						initialize apivk.profiles.js plugin
						
							<br />
							<i>Defined in: </i> <a href="../symbols/src/plugins_apivk.profiles.js.html">apivk.profiles.js</a>.
						
						
					</div>
					
					
					
						
							<dl class="detailList">
							<dt class="heading">Parameters:</dt>
							
								<dt>
									<span class="light fixedFont">{Number}</span> <b>maxCachedRecords</b>
									
								</dt>
								<dd>maximum cached user profiles records</dd>
							
								<dt>
									<span class="light fixedFont">{Number}</span> <b>collectingInterval</b>
									
								</dt>
								<dd>interval collecting uid from
calling <a href="#getProfile">#getProfile</a> for send all in one  request</dd>
							
								<dt>
									<span class="light fixedFont">{Object}</span> <b>fields</b>
									
								</dt>
								<dd>necessary profile fields</dd>
							
							</dl>
						
						
						
						
						
						
						

					<hr />
				
					<a name="makeInstall"> </a>
					<div class="fixedFont">
					
					
					<b>makeInstall</b>(ifInstalled)
					
					</div>
					<div class="description">
						Ask user to install application (add to their page) in indefinite
loop until user finally installs application.
Warning!  Application will ask user to install application until he
did it, so if user don't want to add application to his page, he
can't run application.
						
							<br />
							<i>Defined in: </i> <a href="../symbols/src/plugins_apivk.newuser.js.html">apivk.newuser.js</a>.
						
						
					</div>
					
					
					
						
							<dl class="detailList">
							<dt class="heading">Parameters:</dt>
							
								<dt>
									<span class="light fixedFont">{Function}</span> <b>ifInstalled</b>
									
								</dt>
								<dd>Callback function which executed if and
                            only if application is installed. First
                            time function executes if user installs
                            application after makeInstall() called.
                            But unlike
                            addCallback('onApplicationAdded', ...),
                            this function executes even if
                            application already added before
                            makeInstall() called. This means that if
                            you use makeInstall(fucnName) then
                            funcName() will be executed every time
                            user runs application, even if he
                            installed application only once long time
                            ago.</dd>
							
							</dl>
						
						
						
						
						
						
						

					<hr />
				
					<a name="makeSettings"> </a>
					<div class="fixedFont">
					
					
					<b>makeSettings</b>(settings)
					
					</div>
					<div class="description">
						Ask user to set appropriate settings and wait for user to do it.
Warning! Application will ask user to specify settings until he did
it, so if user don't want to set your settings, he can't run
application.
						
							<br />
							<i>Defined in: </i> <a href="../symbols/src/plugins_apivk.newuser.js.html">apivk.newuser.js</a>.
						
						
					</div>
					
					
					
						
							<dl class="detailList">
							<dt class="heading">Parameters:</dt>
							
								<dt>
									<span class="light fixedFont">{Number}</span> <b>settings</b>
									
								</dt>
								<dd>Settings you want user to set to application.
                       You can use either integer value according to
                       official Vkontakte documentation on
                       http://vkontakte.ru/page7002134 or combination
                       of .SETT_* constants.</dd>
							
							</dl>
						
						
						
						
						
						
						

					<hr />
				
					<a name="removeCallback"> </a>
					<div class="fixedFont">
					
					
					<b>removeCallback</b>(String, Number)
					
					</div>
					<div class="description">
						Remove callback function from the queue.
						
						
					</div>
					
					
					
						
							<dl class="detailList">
							<dt class="heading">Parameters:</dt>
							
								<dt>
									<b>String</b>
									
								</dt>
								<dd>name Name of event from which callback
                   will be removed.</dd>
							
								<dt>
									<b>Number</b>
									
								</dt>
								<dd>callback_id ID of callback function to
                          remove from queue.</dd>
							
							</dl>
						
						
						
						
						
						
						

					
				
			
			
<!-- ============================== event details ========================= -->		
			
			
			<hr />
		</div>

		
<!-- ============================== footer ================================= -->
		<div class="fineprint" style="clear:both">
			
			Documentation generated by <a href="http://code.google.com/p/jsdoc-toolkit/" target="_blank">JsDoc Toolkit</a> 2.3.2 on Sun Mar 14 2010 20:21:54 GMT+0500 (YEKT)
		</div>
	</body>
</html>
